package com.example.calculator;

public class Main {
    public static void main(String[] args) {
        System.out.println("简易计算器 v3.0");
        System.out.println("================");

        Calculator calculator = new Calculator();
        MathUtils mathUtils = new MathUtils();

        // 测试基础运算
        System.out.println("10 + 5 = " + calculator.add(10, 5));
        System.out.println("10 - 5 = " + calculator.subtract(10, 5));

        // 测试数学工具（包含错误）
        System.out.println("5的阶乘 = " + mathUtils.factorial(5));  // 错误：应该输出120，实际输出0
        System.out.println("17是质数吗？ " + mathUtils.isPrime(17));

        System.out.println("版本: " + calculator.getVersion());
    }
}